using Autodesk.Revit.DB;
using Autodesk.Revit.UI;
using System.Collections.Generic;
using System.Threading.Tasks;

namespace CodRevit.Services
{
    /// <summary>
    /// 模拟选择服务接口
    /// </summary>
    public interface ISimulateSelectService
    {
        /// <summary>
        /// 获取可选择的元素列表
        /// </summary>
        /// <param name="doc">Revit文档</param>
        /// <param name="view">当前视图</param>
        /// <returns>可选择的元素列表</returns>
        List<Element> GetSelectableElements(Document doc, Autodesk.Revit.DB.View view);

        /// <summary>
        /// 开始模拟选择过程
        /// </summary>
        /// <param name="uidoc">UI文档</param>
        /// <param name="elements">要选择的元素列表</param>
        /// <returns>异步任务</returns>
        Task StartSimulationAsync(UIDocument uidoc, List<Element> elements, double intervalSeconds = 2.0);

        /// <summary>
        /// 取消模拟选择
        /// </summary>
        void CancelSimulation();
    }
}